// src/characters/enemies/MuralEnemy.cpp
#include "characters/enemies/Enemy.hh"
#include "characters/enemies/MuralEnemy.hh"
#include <iostream>
#include <string>

MuralEnemy::MuralEnemy()
    : Enemy("Mural",
            "A mural that has gained consciousness due to the campus curse.", 
            150,                                                              // Health
            150,                                                              // Max Health
            250,                                                              // Attack (Mental/High)
            20)                                                               // Defense (Low)
{
    std::cout << "The " << getName() << " on the wall shifts and stares!" << std::endl;
}



bool MuralEnemy::attack(ICharacter &target) 
{
    if (!isAlive())
        return false;

    std::cout << getName() << " emits a disorienting psychic shriek at " << target.getName() << "!" << std::endl;

    unsigned damageDealt = getAttackPower();     //gai              
    bool targetSurvived = target.takeDamage(damageDealt); 

    if (!targetSurvived)
    {
        std::cout << target.getName() << "'s mind couldn't withstand the assault!" << std::endl;
    }
    return targetSurvived;
}